﻿<%@ Page Language="C#" MasterPageFile="~/cp/admin/AdminMasterPage.master" AutoEventWireup="true" CodeBehind="editnews.aspx.cs" Inherits="E2_WEBSITE.cp.admin.site.editnews" Title="Cập nhật tin" ErrorPage="~/Common/Error.aspx" %>
<%@ Register TagPrefix="ed" Namespace="OboutInc.Editor" Assembly="obout_Editor" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="body" runat="server">
    <asp:FormView ID="formView" runat="server" Width="100%" 
        DataSourceID="NewsDetail">
        <ItemTemplate>
            Tiêu đề:
            <br />
            <asp:TextBox ID="tbTitle" runat="server" Text='<%# Bind("Title") %>' Width="100%"></asp:TextBox>
            <br />
            <asp:Label ID="lbUser" runat="server" Text='<%# Eval("User") %>'></asp:Label>
            <br />
            <asp:Label ID="lbPubDay" runat="server" Text='<%# Eval("PublishDay") %>'></asp:Label>
            <br />
            <ed:Editor PathPrefix="Editor_data/" id="editor" runat="server" 
                Appearance="lite" Content='<%# Bind("Content") %>' ModeSwitch="False" 
                UpperSuggest="False" AjaxCurrentContent="False" AjaxWait="True" FixedToolBar="True" Show="True" ShowPlaceHolders="False" ShowQuickFormat="False" Submit="False">
            </ed:Editor>
        </ItemTemplate>
    </asp:FormView>
    <center>
        <asp:Button ID="btnUpdate" runat="server" Text="Cập nhật" 
            onclick="btnUpdate_Click" />
        &nbsp;</center>
    <asp:ObjectDataSource ID="NewsDetail" runat="server" SelectMethod="GetNewsInfo" 
        TypeName="E2_WEBSITE.Code.Admin.NewsController">
        <SelectParameters>
            <asp:QueryStringParameter Name="id" QueryStringField="NewsId" Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>
</asp:Content>
<asp:Content ID="Content4" runat="server" contentplaceholderid="info">
Cập nhật thông tin của tin tức và lưu vào cơ sở dữ liệu.	    
</asp:Content>

